import request from '@/utils/request'

// 查询脱密回访记录列表
export function listVisit(query) {
	return request({
		url: '/spm/visit/list',
		method: 'get',
		params: query
	})
}

// 查询脱密回访记录详细
export function getVisit(visitId) {
	return request({
		url: '/spm/visit/' + visitId,
		method: 'get'
	})
}

// 新增脱密回访记录
export function addVisit(data) {
	return request({
		url: '/spm/visit',
		method: 'post',
		data: data
	})
}

// 修改脱密回访记录
export function updateVisit(data) {
	return request({
		url: '/spm/visit',
		method: 'put',
		data: data
	})
}

// 删除脱密回访记录
export function delVisit(visitId) {
	return request({
		url: '/spm/visit/' + visitId,
		method: 'delete'
	})
}